<?php

namespace app\common\model\user;

use think\Hook;
use app\common\model\BaseModel;

/**
 * 用户申请开通商户管理模型
 * Class BusinessApply
 * @package app\common\model\user
 */
class BusinessApply extends BaseModel
{
    protected $name = 'user_business_apply';

    /**
     * 关联会员记录表
     * @return \think\model\relation\BelongsTo
     */
    public function user()
    {
        return $this->belongsTo('app\common\model\User');
    }

    /**
     * 申请记录详情
     * @param $where
     * @return BusinessApply|null
     * @throws \think\exception\DbException
     */
    public static function detail($where)
    {
        return self::get($where);
    }
}